package com.code.softeem.zuoye.demo3;

/**
 * @author xiyu
 * @version 1.0
 * @date 2025/3/20 17:24
 * @description
 */
public class BankCard {
    private static int nextNo=0;//银行卡序号
    private static double totalBalance=0;//所有卡累计余额
    private String cardNo;//银行卡号
    private String name;//客户姓名
    private String personId;//客户身份证号
    private double balance = 0;//卡上余额

    public BankCard() {
    }

    public BankCard(int nextNo, double totalBalance, String cardNo, String name, String personId, double balance) {
        this.nextNo = nextNo;
        this.totalBalance = totalBalance;
        this.cardNo = cardNo;
        this.name = name;
        this.personId = personId;
        this.balance = balance;
    }

    public int getNextNo() {
        return nextNo;
    }

    public void setNextNo(int nextNo) {
        this.nextNo = nextNo;
    }

    public static double getTotalBalance() {
        return totalBalance;
    }

    public static void setTotalBalance(double totalBalance) {
        BankCard.totalBalance = totalBalance;
    }

    public String getCardNo() {
        return cardNo;
    }

    public void setCardNo(String cardNo) {
        this.cardNo = cardNo;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPersonId() {
        return personId;
    }

    public void setPersonId(String personId) {
        this.personId = personId;
    }

    public double getBalance() {
        return balance;
    }

    public void setBalance(double balance) {
        this.balance = balance;
    }

    public void getCurrentCardNo() {

    }

    public void getNextCurrentNo() {

    }
    public void deposit() {//存款

    }
    public void withdraw() {//取款

    }




    @Override
    public String toString() {
        return "BankCard{" +
                "nextNo=" + nextNo +
                ", totalBalance=" + totalBalance +
                ", cardNo='" + cardNo + '\'' +
                ", name='" + name + '\'' +
                ", personId='" + personId + '\'' +
                ", balance=" + balance +
                '}';
    }
}
